#ifndef __MYGLIB_H__
#define __MYGLIB_H__

#include <glib.h>

typedef gpointer (*GCollectFunc) (guint     key,
                                  gpointer  value,
                                  gpointer  user_data);

typedef gpointer (*GHCollectFunc) (gpointer  key,
                                   gpointer  value,
                                   gpointer  user_data);

GList* g_list_collect (GList        *list,
                       GCollectFunc  func,
                       gpointer      user_data);

void g_hash_table_insert_all (GHashTable  *hashtable,
                              GHashTable  *items);

GHashTable *g_hash_table_collect (GHashTable    *hashtable,
                                  GHCollectFunc  func,
                                  gpointer       user_data,
                                  GHashFunc      hash,
                                  GCompareFunc   compare);
#endif
